package com.hmall.search.pojo;

import com.hmall.common.dto.Item;
import lombok.Data;
import lombok.NoArgsConstructor;

@Data
@NoArgsConstructor
public class ItemDoc {
    private Long id;
    private String name;
    private Long price;
    private String image;
    private String category;
    private String brand;
    private Integer sold;
    private Integer commentCount;
    private Boolean isAD;

    public ItemDoc(Item hotel) {
        this.id = hotel.getId();
        this.name = hotel.getName();
        this.price = hotel.getPrice();
        this.brand = hotel.getBrand();
        this.image = hotel.getImage();
        this.category = hotel.getCategory();
        this.sold = hotel.getSold();
        this.commentCount = hotel.getCommentCount();
        this.isAD = hotel.getIsAD();

    }


}
